package com.gorkr.labuladong.data_struct.array;

/**
 * @author gorkr
 * @date 2022/06/03 11:44
 **/
public class E344ReverseString {
    public void reverseString(char[] s) {
        int left = 0, right = s.length - 1;
        char tmp;
        while (left <= right) {
            tmp = s[right];
            s[right] = s[left];
            s[left] = tmp;
            left++;
            right--;
        }
    }
}
    